﻿using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Data;

namespace Mes.Client.Converters
{
    class L2SConverter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            var textLength=(int )value;
            if (textLength>6)
            {
                return 14;
            }
            else if (textLength>5)
            {
                return 16;
            }
            else if(textLength>4)
            {
                return 18;
            }
            else
            {
                return 20;
            }
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}
